<template>
	<view>
		<uni-forms :modelValue="formData" label-position="left">
			<uni-forms-item label="姓名" name="name">
				<uni-easyinput type="text" v-model="formData.name" placeholder="请输入姓名" />
			</uni-forms-item>
			<uni-forms-item label="身份证" name="id_card">
				<uni-easyinput type="text" v-model="formData.id_card" placeholder="请输入身份证" />
			</uni-forms-item>
			<uni-forms-item label="手机号" name="phone">
				<uni-easyinput type="text" v-model="formData.phone" placeholder="请输入手机号" />
			</uni-forms-item>
			<uni-forms-item label="现居地址" name="address">
				<uni-data-picker placeholder="请选择地址" v-model="formData.address" popup-title="请选择城市"
					collection="opendb-city-china" field="code as value, name as text" orderby="value asc"
					:step-searh="true" self-field="code" parent-field="parent_code" @change="onchange"
					@nodeclick="onnodeclick">
				</uni-data-picker>
			</uni-forms-item>
			<uni-forms-item label="现居详细地址" name="de_address">
				<uni-easyinput type="text" v-model="formData.de_address" placeholder="请输入姓名" />
			</uni-forms-item>
			<uni-forms-item label="疫苗人群分类" name="crowd_sort">
				<uni-easyinput type="text" v-model="formData.crowd_sort" placeholder="请输入姓名" />
			</uni-forms-item>
		</uni-forms>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				formData: {
					name: '',
					id_card: '',
					phone: '',
					address: '',
					de_address: '',
					crowd_sort: ''
				},
				role: ['医疗卫生人员', '卫生系统内工作的其他人员', '因公出国人员',
					'对外劳务派遣人员', '留学生', '因私出国人员', '海关边检人员', '公安系统,消防人员',
					'党政机关,事业单位人员', '社区工作者', '教育工作者', '小学和中学学生', '其他人员'
			]
	
			};
		},

		methods: {
			onchange(e) {
				const value = e.detail.value
			},
			onnodeclick(node) {}
		},
		onload() {

		}
	}
</script>

<style lang="scss">

</style>
